// ******************************************************************************
// Copyright     :  Copyright (C) 2019, Hisilicon Technologies Co. Ltd.
// File name     :  esch_c_union_define.h
// Project line  :  Platform And Key Technologies Development
// Department    :  CAD Development Department
// Author        :  xxx
// Version       :  1.0
// Date          :  2018/12/11
// Description   :  The description of xxx project
// Others        :  Generated automatically by nManager V5.1
// History       :  xxx 2019/12/11 20:09:30 Create file
// ******************************************************************************

#ifndef ESCH_C_UNION_DEFINE_H
#define ESCH_C_UNION_DEFINE_H

/* Define the union csr_esch_cos_ch_map_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 cos_ch_map_link : 6; /* [5:0] */
        u32 rsv_0 : 26;          /* [31:6] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_cos_ch_map_u;

/* Define the union csr_esch_mem_cfg_ok_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 cfg_ok : 1; /* [0] */
        u32 rsv_1 : 31; /* [31:1] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_mem_cfg_ok_u;

/* Define the union csr_esch_ppop_bp_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_q_bp_mask : 1;     /* [0] */
        u32 rsv_2 : 3;             /* [3:1] */
        u32 eps_q_grp_csr_cfg : 7; /* [10:4] */
        u32 rsv_3 : 21;            /* [31:11] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_ppop_bp_cfg_u;

/* Define the union csr_esch_ppop_bp_st_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_q_grp_bp_st : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_ppop_bp_st_u;

/* Define the union csr_esch_lb_prm_bp_map_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 prm_lb_cos_map : 6; /* [5:0] */
        u32 rsv_4 : 26;         /* [31:6] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_lb_prm_bp_map_u;

/* Define the union csr_esch_host_fifo_th_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 cpb_host_fifo_th : 5; /* [4:0] */
        u32 rsv_5 : 27;           /* [31:5] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_host_fifo_th_u;

/* Define the union csr_esch_hostlb_fifo_th_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 cpb_host_lb_fifo_th : 5; /* [4:0] */
        u32 rsv_6 : 27;              /* [31:5] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hostlb_fifo_th_u;

/* Define the union csr_esch_net_fifo_th_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 cpb_net_fifo_th : 5; /* [4:0] */
        u32 rsv_7 : 27;          /* [31:5] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_net_fifo_th_u;

/* Define the union csr_esch_netlb_fifo_th_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 cpb_net_lb_fifo_th : 5; /* [4:0] */
        u32 rsv_8 : 27;             /* [31:5] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_netlb_fifo_th_u;

/* Define the union csr_esch_mem_ctrl_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 mem_init_start : 1;  /* [0] */
        u32 mem_power_ctrl : 3;  /* [3:1] */
        u32 mem_timing_ctrl : 7; /* [10:4] */
        u32 mem_ecc_enable : 1;  /* [11] */
        u32 mem_init_done : 1;   /* [12] */
        u32 rsv_9 : 19;          /* [31:13] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_mem_ctrl_u;

/* Define the union csr_esch_mem_err_req0_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_ram_err_req0 : 16; /* [15:0] */
        u32 eps_ram_err_req1 : 16; /* [31:16] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_mem_err_req0_u;

/* Define the union csr_esch_mem_err_req1_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_ram_err_req4 : 2; /* [1:0] */
        u32 eps_ram_err_req3 : 2; /* [3:2] */
        u32 eps_ram_err_req2 : 2; /* [5:4] */
        u32 hps_ram_err_req2 : 2; /* [7:6] */
        u32 hps_ram_err_req1 : 2; /* [9:8] */
        u32 hps_ram_err_req0 : 2; /* [11:10] */
        u32 rsv_10 : 20;          /* [31:12] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_mem_err_req1_u;

/* Define the union csr_esch_int_vector_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 cpi_int_index : 24; /* [23:0] */
        u32 rsv_11 : 3;         /* [26:24] */
        u32 enable : 1;         /* [27] */
        u32 int_issue : 1;      /* [28] */
        u32 rsv_12 : 3;         /* [31:29] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_int_vector_u;

/* Define the union csr_esch_int_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 int_data : 6;           /* [5:0] */
        u32 rsv_13 : 10;            /* [15:6] */
        u32 program_csr_id_ro : 16; /* [31:16] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_int_u;

/* Define the union csr_esch_int_en_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 int_en : 6;          /* [5:0] */
        u32 rsv_14 : 10;         /* [15:6] */
        u32 program_csr_id : 16; /* [31:16] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_int_en_u;

/* Define the union csr_esch_int0_sticky0_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 esch_mem_err0 : 1;     /* [0] */
        u32 int_insrt0 : 1;        /* [1] */
        u32 esch_int0_sticky : 30; /* [31:2] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_int0_sticky0_u;

/* Define the union csr_esch_int0_sticky1_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 esch_mem_err1 : 1;     /* [0] */
        u32 int_insrt1 : 1;        /* [1] */
        u32 esch_int1_sticky : 30; /* [31:2] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_int0_sticky1_u;

/* Define the union csr_esch_int0_sticky2_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 esch_fifo_err : 1;    /* [0] */
        u32 int_insrt2 : 1;       /* [1] */
        u32 esch_int2_sticky : 4; /* [5:2] */
        u32 rsv_15 : 26;          /* [31:6] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_int0_sticky2_u;

/* Define the union csr_esch_fcnp_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 fcnp_ref_size_cfg : 10; /* [9:0] */
        u32 rsv_16 : 22;            /* [31:10] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_fcnp_cfg_u;

/* Define the union csr_esch_cpb_ch_cdt_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 cpb_chan_credit : 5; /* [4:0] */
        u32 cpb_chan_id : 6;     /* [10:5] */
        u32 cpb_chan_type : 3;   /* [13:11] */
        u32 rsv_17 : 18;         /* [31:14] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_cpb_ch_cdt_cfg_u;

/* Define the union csr_esch_hps_nml_cos_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_normal_cos_bp : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_nml_cos_bp_u;

/* Define the union csr_esch_hps_up_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_mpu_bp : 1;     /* [0] */
        u32 hps_spu_cos_bp : 8; /* [8:1] */
        u32 rsv_18 : 23;        /* [31:9] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_up_bp_u;

/* Define the union csr_esch_hps_lb_cos_high_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_cos_high_bp : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_cos_high_bp_u;

/* Define the union csr_esch_hps_lb_cos_low_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_cos_low_bp : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_cos_low_bp_u;

/* Define the union csr_esch_eps_cos_high_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_cos_high_bp : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_eps_cos_high_bp_u;

/* Define the union csr_esch_eps_cos_low_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_cos_low_bp : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_eps_cos_low_bp_u;

/* Define the union csr_esch_eps_lb_type_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_type_bp : 3; /* [2:0] */
        u32 rsv_19 : 29;        /* [31:3] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_eps_lb_type_bp_u;

/* Define the union csr_esch_mag_high_cos_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 mag_esch_chan_bp_high32 : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_mag_high_cos_bp_u;

/* Define the union csr_esch_mag_low_cos_bp_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 mag_esch_chan_bp_low32 : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_mag_low_cos_bp_u;


// ==============================================================================
/* Define the global struct */
typedef struct {
    volatile csr_esch_cos_ch_map_u esch_cos_ch_map[40];             /* 0 */
    volatile csr_esch_mem_cfg_ok_u esch_mem_cfg_ok;                 /* A0 */
    volatile csr_esch_ppop_bp_cfg_u esch_ppop_bp_cfg;               /* A4 */
    volatile csr_esch_ppop_bp_st_u esch_ppop_bp_st;                 /* A8 */
    volatile csr_esch_lb_prm_bp_map_u esch_lb_prm_bp_map[192];      /* 100 */
    volatile csr_esch_host_fifo_th_u esch_host_fifo_th[33];         /* 400 */
    volatile csr_esch_hostlb_fifo_th_u esch_hostlb_fifo_th[64];     /* 500 */
    volatile csr_esch_net_fifo_th_u esch_net_fifo_th[64];           /* 600 */
    volatile csr_esch_netlb_fifo_th_u esch_netlb_fifo_th[3];        /* 700 */
    volatile csr_esch_mem_ctrl_u esch_mem_ctrl;                     /* 750 */
    volatile csr_esch_mem_err_req0_u esch_mem_err_req0;             /* 754 */
    volatile csr_esch_mem_err_req1_u esch_mem_err_req1;             /* 758 */
    volatile csr_esch_int_vector_u esch_int_vector;                 /* 760 */
    volatile csr_esch_int_u esch_int;                               /* 764 */
    volatile csr_esch_int_en_u esch_int_en;                         /* 768 */
    volatile csr_esch_int0_sticky0_u esch_int0_sticky0;             /* 76C */
    volatile csr_esch_int0_sticky1_u esch_int0_sticky1;             /* 770 */
    volatile csr_esch_int0_sticky2_u esch_int0_sticky2;             /* 774 */
    volatile csr_esch_fcnp_cfg_u esch_fcnp_cfg;                     /* 778 */
    volatile csr_esch_cpb_ch_cdt_cfg_u esch_cpb_ch_cdt_cfg;         /* 77C */
    volatile csr_esch_hps_nml_cos_bp_u esch_hps_nml_cos_bp;         /* 780 */
    volatile csr_esch_hps_up_bp_u esch_hps_up_bp;                   /* 784 */
    volatile csr_esch_hps_lb_cos_high_bp_u esch_hps_lb_cos_high_bp; /* 788 */
    volatile csr_esch_hps_lb_cos_low_bp_u esch_hps_lb_cos_low_bp;   /* 78C */
    volatile csr_esch_eps_cos_high_bp_u esch_eps_cos_high_bp;       /* 790 */
    volatile csr_esch_eps_cos_low_bp_u esch_eps_cos_low_bp;         /* 794 */
    volatile csr_esch_eps_lb_type_bp_u esch_eps_lb_type_bp;         /* 79C */
    volatile csr_esch_mag_high_cos_bp_u esch_mag_high_cos_bp;       /* 7A0 */
    volatile csr_esch_mag_low_cos_bp_u esch_mag_low_cos_bp;         /* 7A4 */
} S_esch_top_csr_REGS_TYPE;

/* Declare the struct pointor of the module esch_top_csr */
extern volatile S_esch_top_csr_REGS_TYPE *gopesch_top_csrAllReg;

/* Declare the functions that set the member value */
int iSetESCH_COS_CH_MAP_cos_ch_map_link(unsigned int ucos_ch_map_link);
int iSetESCH_MEM_CFG_OK_cfg_ok(unsigned int ucfg_ok);
int iSetESCH_PPOP_BP_CFG_eps_q_bp_mask(unsigned int ueps_q_bp_mask);
int iSetESCH_PPOP_BP_CFG_eps_q_grp_csr_cfg(unsigned int ueps_q_grp_csr_cfg);
int iSetESCH_PPOP_BP_ST_eps_q_grp_bp_st(unsigned int ueps_q_grp_bp_st);
int iSetESCH_LB_PRM_BP_MAP_prm_lb_cos_map(unsigned int uprm_lb_cos_map);
int iSetESCH_HOST_FIFO_TH_cpb_host_fifo_th(unsigned int ucpb_host_fifo_th);
int iSetESCH_HOSTLB_FIFO_TH_cpb_host_lb_fifo_th(unsigned int ucpb_host_lb_fifo_th);
int iSetESCH_NET_FIFO_TH_cpb_net_fifo_th(unsigned int ucpb_net_fifo_th);
int iSetESCH_NETLB_FIFO_TH_cpb_net_lb_fifo_th(unsigned int ucpb_net_lb_fifo_th);
int iSetESCH_MEM_CTRL_mem_init_start(unsigned int umem_init_start);
int iSetESCH_MEM_CTRL_mem_power_ctrl(unsigned int umem_power_ctrl);
int iSetESCH_MEM_CTRL_mem_timing_ctrl(unsigned int umem_timing_ctrl);
int iSetESCH_MEM_CTRL_mem_ecc_enable(unsigned int umem_ecc_enable);
int iSetESCH_MEM_CTRL_mem_init_done(unsigned int umem_init_done);
int iSetESCH_MEM_ERR_REQ0_eps_ram_err_req0(unsigned int ueps_ram_err_req0);
int iSetESCH_MEM_ERR_REQ0_eps_ram_err_req1(unsigned int ueps_ram_err_req1);
int iSetESCH_MEM_ERR_REQ1_eps_ram_err_req4(unsigned int ueps_ram_err_req4);
int iSetESCH_MEM_ERR_REQ1_eps_ram_err_req3(unsigned int ueps_ram_err_req3);
int iSetESCH_MEM_ERR_REQ1_eps_ram_err_req2(unsigned int ueps_ram_err_req2);
int iSetESCH_MEM_ERR_REQ1_hps_ram_err_req2(unsigned int uhps_ram_err_req2);
int iSetESCH_MEM_ERR_REQ1_hps_ram_err_req1(unsigned int uhps_ram_err_req1);
int iSetESCH_MEM_ERR_REQ1_hps_ram_err_req0(unsigned int uhps_ram_err_req0);
int iSetESCH_INT_VECTOR_cpi_int_index(unsigned int ucpi_int_index);
int iSetESCH_INT_VECTOR_enable(unsigned int uenable);
int iSetESCH_INT_VECTOR_int_issue(unsigned int uint_issue);
int iSetESCH_INT_int_data(unsigned int uint_data);
int iSetESCH_INT_program_csr_id_ro(unsigned int uprogram_csr_id_ro);
int iSetESCH_INT_EN_int_en(unsigned int uint_en);
int iSetESCH_INT_EN_program_csr_id(unsigned int uprogram_csr_id);
int iSetESCH_INT0_STICKY0_esch_mem_err0(unsigned int uesch_mem_err0);
int iSetESCH_INT0_STICKY0_int_insrt0(unsigned int uint_insrt0);
int iSetESCH_INT0_STICKY0_esch_int0_sticky(unsigned int uesch_int0_sticky);
int iSetESCH_INT0_STICKY1_esch_mem_err1(unsigned int uesch_mem_err1);
int iSetESCH_INT0_STICKY1_int_insrt1(unsigned int uint_insrt1);
int iSetESCH_INT0_STICKY1_esch_int1_sticky(unsigned int uesch_int1_sticky);
int iSetESCH_INT0_STICKY2_esch_fifo_err(unsigned int uesch_fifo_err);
int iSetESCH_INT0_STICKY2_int_insrt2(unsigned int uint_insrt2);
int iSetESCH_INT0_STICKY2_esch_int2_sticky(unsigned int uesch_int2_sticky);
int iSetESCH_FCNP_CFG_fcnp_ref_size_cfg(unsigned int ufcnp_ref_size_cfg);
int iSetESCH_CPB_CH_CDT_CFG_cpb_chan_credit(unsigned int ucpb_chan_credit);
int iSetESCH_CPB_CH_CDT_CFG_cpb_chan_id(unsigned int ucpb_chan_id);
int iSetESCH_CPB_CH_CDT_CFG_cpb_chan_type(unsigned int ucpb_chan_type);
int iSetESCH_HPS_NML_COS_BP_hps_normal_cos_bp(unsigned int uhps_normal_cos_bp);
int iSetESCH_HPS_UP_BP_hps_mpu_bp(unsigned int uhps_mpu_bp);
int iSetESCH_HPS_UP_BP_hps_spu_cos_bp(unsigned int uhps_spu_cos_bp);
int iSetESCH_HPS_LB_COS_HIGH_BP_hps_lb_cos_high_bp(unsigned int uhps_lb_cos_high_bp);
int iSetESCH_HPS_LB_COS_LOW_BP_hps_lb_cos_low_bp(unsigned int uhps_lb_cos_low_bp);
int iSetESCH_EPS_COS_HIGH_BP_eps_cos_high_bp(unsigned int ueps_cos_high_bp);
int iSetESCH_EPS_COS_LOW_BP_eps_cos_low_bp(unsigned int ueps_cos_low_bp);
int iSetESCH_EPS_LB_TYPE_BP_eps_lb_type_bp(unsigned int ueps_lb_type_bp);
int iSetESCH_MAG_HIGH_COS_BP_mag_esch_chan_bp_high32(unsigned int umag_esch_chan_bp_high32);
int iSetESCH_MAG_LOW_COS_BP_mag_esch_chan_bp_low32(unsigned int umag_esch_chan_bp_low32);

/* Define the union csr_eps_q_indrect_ctrl_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_q_indrect_addr : 24; /* [23:0] */
        u32 eps_q_indrect_tab : 4;   /* [27:24] */
        u32 eps_q_indrect_stat : 2;  /* [29:28] */
        u32 eps_q_indrect_mode : 1;  /* [30] */
        u32 eps_q_indrect_vld : 1;   /* [31] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_q_indrect_ctrl_u;

/* Define the union csr_eps_q_indrect_timeout_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_q_indrect_timeout : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_q_indrect_timeout_u;

/* Define the union csr_eps_q_indrect_data_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_q_indrect_data : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_q_indrect_data_u;

/* Define the union csr_eps_cos_indrect_ctrl_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_cos_indrect_addr : 24; /* [23:0] */
        u32 eps_cos_indrect_tab : 4;   /* [27:24] */
        u32 eps_cos_indrect_stat : 2;  /* [29:28] */
        u32 eps_cos_indrect_mode : 1;  /* [30] */
        u32 eps_cos_indrect_vld : 1;   /* [31] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_cos_indrect_ctrl_u;

/* Define the union csr_eps_cos_indrect_timeout_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_cos_indrect_timeout : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_cos_indrect_timeout_u;

/* Define the union csr_eps_cos_indrect_data_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_cos_indrect_data : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_cos_indrect_data_u;

/* Define the union csr_eps_tc_p_indrect_ctrl_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_tc_p_indrect_addr : 24; /* [23:0] */
        u32 eps_tc_p_indrect_tab : 4;   /* [27:24] */
        u32 eps_tc_p_indrect_stat : 2;  /* [29:28] */
        u32 eps_tc_p_indrect_mode : 1;  /* [30] */
        u32 eps_tc_p_indrect_vld : 1;   /* [31] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_tc_p_indrect_ctrl_u;

/* Define the union csr_eps_tc_p_indrect_timeout_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_tc_p_indrect_timeout : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_tc_p_indrect_timeout_u;

/* Define the union csr_eps_tc_p_indrect_data_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_tc_p_indrect_data : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_tc_p_indrect_data_u;

/* Define the union csr_eps_lb_q_indrect_ctrl_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_q_indrect_addr : 24; /* [23:0] */
        u32 eps_lb_q_indrect_tab : 4;   /* [27:24] */
        u32 eps_lb_q_indrect_stat : 2;  /* [29:28] */
        u32 eps_lb_q_indrect_mode : 1;  /* [30] */
        u32 eps_lb_q_indrect_vld : 1;   /* [31] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_q_indrect_ctrl_u;

/* Define the union csr_eps_lb_q_indrect_timeout_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_q_indrect_timeout : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_q_indrect_timeout_u;

/* Define the union csr_eps_lb_q_indrect_data_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_q_indrect_data : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_q_indrect_data_u;

/* Define the union csr_eps_lb_p_t_indrect_ctrl_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_p_t_indrect_addr : 24; /* [23:0] */
        u32 eps_lb_p_t_indrect_tab : 4;   /* [27:24] */
        u32 eps_lb_p_t_indrect_stat : 2;  /* [29:28] */
        u32 eps_lb_p_t_indrect_mode : 1;  /* [30] */
        u32 eps_lb_p_t_indrect_vld : 1;   /* [31] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_p_t_indrect_ctrl_u;

/* Define the union csr_eps_lb_p_t_indrect_timeout_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_p_t_indrect_timeout : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_p_t_indrect_timeout_u;

/* Define the union csr_eps_lb_p_t_indrect_data_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_p_t_indrect_data : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_p_t_indrect_data_u;

/* Define the union csr_eps_p_soft_bp_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_port_soft_bp_cfg : 8; /* [7:0] */
        u32 rsv_0 : 24;               /* [31:8] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_p_soft_bp_cfg_u;

/* Define the union csr_eps_cos_bp_en0_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_cos_bp_en_p0 : 8; /* [7:0] */
        u32 eps_cos_bp_en_p1 : 8; /* [15:8] */
        u32 eps_cos_bp_en_p2 : 8; /* [23:16] */
        u32 eps_cos_bp_en_p3 : 8; /* [31:24] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_cos_bp_en0_u;

/* Define the union csr_eps_cos_bp_en1_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_cos_bp_en_p4 : 8; /* [7:0] */
        u32 eps_cos_bp_en_p5 : 8; /* [15:8] */
        u32 eps_cos_bp_en_p6 : 8; /* [23:16] */
        u32 eps_cos_bp_en_p7 : 8; /* [31:24] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_cos_bp_en1_u;

/* Define the union csr_eps_bp_mode_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_bp_mode : 8;  /* [7:0] */
        u32 eps_rw_rsv0 : 24; /* [31:8] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_bp_mode_u;

/* Define the union csr_eps_root_cir_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_port_grp_cir_cfg : 25; /* [24:0] */
        u32 rsv_1 : 7;                 /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_root_cir_cfg_u;

/* Define the union csr_eps_lb_root_cir_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_cir_cfg : 25; /* [24:0] */
        u32 rsv_2 : 7;           /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_root_cir_cfg_u;

/* Define the union csr_eps_all_cir_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_all_cir_cfg : 25; /* [24:0] */
        u32 rsv_3 : 7;            /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_all_cir_cfg_u;

/* Define the union csr_eps_root_cir_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_root_cir_cnt : 26; /* [25:0] */
        u32 rsv_4 : 6;             /* [31:26] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_root_cir_cnt_u;

/* Define the union csr_eps_lb_root_cir_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_root_cir_cnt : 26; /* [25:0] */
        u32 rsv_5 : 6;                /* [31:26] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_root_cir_cnt_u;

/* Define the union csr_eps_root_wgt_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_root_wgt_cfg : 24; /* [23:0] */
        u32 rsv_6 : 8;             /* [31:24] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_root_wgt_cfg_u;

/* Define the union csr_eps_nml_root_wgt_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_nml_root_wgt_cnt : 25; /* [24:0] */
        u32 rsv_7 : 7;                 /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_nml_root_wgt_cnt_u;

/* Define the union csr_eps_lb_root_wgt_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_lb_root_wgt_cnt : 25; /* [24:0] */
        u32 rsv_8 : 7;                /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_lb_root_wgt_cnt_u;

/* Define the union csr_eps_ecc_1bit_err_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_mem_ecc_err0 : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_ecc_1bit_err_cnt_u;

/* Define the union csr_eps_ecc_2bit_err_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_mem_ecc_err1 : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_ecc_2bit_err_cnt_u;

/* Define the union csr_eps_dqs_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_dqs_rec : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_dqs_cnt_u;

/* Define the union csr_eps_eqs_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_eqs_rec : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_eqs_cnt_u;

/* Define the union csr_eps_fifo_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 eps_fifo_cnt : 4; /* [3:0] */
        u32 rsv_9 : 28;       /* [31:4] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_fifo_cnt_u;

/* Define the union csr_eps_inner_err_st_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 sel_queue_err : 1; /* [0] */
        u32 dqs_qid_err : 1;   /* [1] */
        u32 dqs_over_err : 1;  /* [2] */
        u32 dqs_late_err : 1;  /* [3] */
        u32 rsv_10 : 28;       /* [31:4] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_eps_inner_err_st_u;


// ==============================================================================
/* Define the global struct */
typedef struct {
    volatile csr_eps_q_indrect_ctrl_u eps_q_indrect_ctrl;                 /* 0 */
    volatile csr_eps_q_indrect_timeout_u eps_q_indrect_timeout;           /* 4 */
    volatile csr_eps_q_indrect_data_u eps_q_indrect_data;                 /* 8 */
    volatile csr_eps_cos_indrect_ctrl_u eps_cos_indrect_ctrl;             /* 10 */
    volatile csr_eps_cos_indrect_timeout_u eps_cos_indrect_timeout;       /* 14 */
    volatile csr_eps_cos_indrect_data_u eps_cos_indrect_data;             /* 18 */
    volatile csr_eps_tc_p_indrect_ctrl_u eps_tc_p_indrect_ctrl;           /* 20 */
    volatile csr_eps_tc_p_indrect_timeout_u eps_tc_p_indrect_timeout;     /* 24 */
    volatile csr_eps_tc_p_indrect_data_u eps_tc_p_indrect_data;           /* 28 */
    volatile csr_eps_lb_q_indrect_ctrl_u eps_lb_q_indrect_ctrl;           /* 30 */
    volatile csr_eps_lb_q_indrect_timeout_u eps_lb_q_indrect_timeout;     /* 34 */
    volatile csr_eps_lb_q_indrect_data_u eps_lb_q_indrect_data;           /* 38 */
    volatile csr_eps_lb_p_t_indrect_ctrl_u eps_lb_p_t_indrect_ctrl;       /* 40 */
    volatile csr_eps_lb_p_t_indrect_timeout_u eps_lb_p_t_indrect_timeout; /* 44 */
    volatile csr_eps_lb_p_t_indrect_data_u eps_lb_p_t_indrect_data;       /* 48 */
    volatile csr_eps_p_soft_bp_cfg_u eps_p_soft_bp_cfg;                   /* 50 */
    volatile csr_eps_cos_bp_en0_u eps_cos_bp_en0;                         /* 54 */
    volatile csr_eps_cos_bp_en1_u eps_cos_bp_en1;                         /* 58 */
    volatile csr_eps_bp_mode_u eps_bp_mode;                               /* 5C */
    volatile csr_eps_root_cir_cfg_u eps_root_cir_cfg;                     /* 60 */
    volatile csr_eps_lb_root_cir_cfg_u eps_lb_root_cir_cfg;               /* 64 */
    volatile csr_eps_all_cir_cfg_u eps_all_cir_cfg;                       /* 68 */
    volatile csr_eps_root_cir_cnt_u eps_root_cir_cnt;                     /* 6C */
    volatile csr_eps_lb_root_cir_cnt_u eps_lb_root_cir_cnt;               /* 70 */
    volatile csr_eps_root_wgt_cfg_u eps_root_wgt_cfg;                     /* 78 */
    volatile csr_eps_nml_root_wgt_cnt_u eps_nml_root_wgt_cnt;             /* 80 */
    volatile csr_eps_lb_root_wgt_cnt_u eps_lb_root_wgt_cnt;               /* 84 */
    volatile csr_eps_ecc_1bit_err_cnt_u eps_ecc_1bit_err_cnt;             /* 100 */
    volatile csr_eps_ecc_2bit_err_cnt_u eps_ecc_2bit_err_cnt;             /* 104 */
    volatile csr_eps_dqs_cnt_u eps_dqs_cnt;                               /* 108 */
    volatile csr_eps_eqs_cnt_u eps_eqs_cnt;                               /* 10C */
    volatile csr_eps_fifo_cnt_u eps_fifo_cnt;                             /* 110 */
    volatile csr_eps_inner_err_st_u eps_inner_err_st;                     /* 114 */
} S_esch_eps_csr_REGS_TYPE;

/* Declare the struct pointor of the module esch_eps_csr */
extern volatile S_esch_eps_csr_REGS_TYPE *gopesch_eps_csrAllReg;

/* Declare the functions that set the member value */
int iSetEPS_Q_INDRECT_CTRL_eps_q_indrect_addr(unsigned int ueps_q_indrect_addr);
int iSetEPS_Q_INDRECT_CTRL_eps_q_indrect_tab(unsigned int ueps_q_indrect_tab);
int iSetEPS_Q_INDRECT_CTRL_eps_q_indrect_stat(unsigned int ueps_q_indrect_stat);
int iSetEPS_Q_INDRECT_CTRL_eps_q_indrect_mode(unsigned int ueps_q_indrect_mode);
int iSetEPS_Q_INDRECT_CTRL_eps_q_indrect_vld(unsigned int ueps_q_indrect_vld);
int iSetEPS_Q_INDRECT_TIMEOUT_eps_q_indrect_timeout(unsigned int ueps_q_indrect_timeout);
int iSetEPS_Q_INDRECT_DATA_eps_q_indrect_data(unsigned int ueps_q_indrect_data);
int iSetEPS_COS_INDRECT_CTRL_eps_cos_indrect_addr(unsigned int ueps_cos_indrect_addr);
int iSetEPS_COS_INDRECT_CTRL_eps_cos_indrect_tab(unsigned int ueps_cos_indrect_tab);
int iSetEPS_COS_INDRECT_CTRL_eps_cos_indrect_stat(unsigned int ueps_cos_indrect_stat);
int iSetEPS_COS_INDRECT_CTRL_eps_cos_indrect_mode(unsigned int ueps_cos_indrect_mode);
int iSetEPS_COS_INDRECT_CTRL_eps_cos_indrect_vld(unsigned int ueps_cos_indrect_vld);
int iSetEPS_COS_INDRECT_TIMEOUT_eps_cos_indrect_timeout(unsigned int ueps_cos_indrect_timeout);
int iSetEPS_COS_INDRECT_DATA_eps_cos_indrect_data(unsigned int ueps_cos_indrect_data);
int iSetEPS_TC_P_INDRECT_CTRL_eps_tc_p_indrect_addr(unsigned int ueps_tc_p_indrect_addr);
int iSetEPS_TC_P_INDRECT_CTRL_eps_tc_p_indrect_tab(unsigned int ueps_tc_p_indrect_tab);
int iSetEPS_TC_P_INDRECT_CTRL_eps_tc_p_indrect_stat(unsigned int ueps_tc_p_indrect_stat);
int iSetEPS_TC_P_INDRECT_CTRL_eps_tc_p_indrect_mode(unsigned int ueps_tc_p_indrect_mode);
int iSetEPS_TC_P_INDRECT_CTRL_eps_tc_p_indrect_vld(unsigned int ueps_tc_p_indrect_vld);
int iSetEPS_TC_P_INDRECT_TIMEOUT_eps_tc_p_indrect_timeout(unsigned int ueps_tc_p_indrect_timeout);
int iSetEPS_TC_P_INDRECT_DATA_eps_tc_p_indrect_data(unsigned int ueps_tc_p_indrect_data);
int iSetEPS_LB_Q_INDRECT_CTRL_eps_lb_q_indrect_addr(unsigned int ueps_lb_q_indrect_addr);
int iSetEPS_LB_Q_INDRECT_CTRL_eps_lb_q_indrect_tab(unsigned int ueps_lb_q_indrect_tab);
int iSetEPS_LB_Q_INDRECT_CTRL_eps_lb_q_indrect_stat(unsigned int ueps_lb_q_indrect_stat);
int iSetEPS_LB_Q_INDRECT_CTRL_eps_lb_q_indrect_mode(unsigned int ueps_lb_q_indrect_mode);
int iSetEPS_LB_Q_INDRECT_CTRL_eps_lb_q_indrect_vld(unsigned int ueps_lb_q_indrect_vld);
int iSetEPS_LB_Q_INDRECT_TIMEOUT_eps_lb_q_indrect_timeout(unsigned int ueps_lb_q_indrect_timeout);
int iSetEPS_LB_Q_INDRECT_DATA_eps_lb_q_indrect_data(unsigned int ueps_lb_q_indrect_data);
int iSetEPS_LB_P_T_INDRECT_CTRL_eps_lb_p_t_indrect_addr(unsigned int ueps_lb_p_t_indrect_addr);
int iSetEPS_LB_P_T_INDRECT_CTRL_eps_lb_p_t_indrect_tab(unsigned int ueps_lb_p_t_indrect_tab);
int iSetEPS_LB_P_T_INDRECT_CTRL_eps_lb_p_t_indrect_stat(unsigned int ueps_lb_p_t_indrect_stat);
int iSetEPS_LB_P_T_INDRECT_CTRL_eps_lb_p_t_indrect_mode(unsigned int ueps_lb_p_t_indrect_mode);
int iSetEPS_LB_P_T_INDRECT_CTRL_eps_lb_p_t_indrect_vld(unsigned int ueps_lb_p_t_indrect_vld);
int iSetEPS_LB_P_T_INDRECT_TIMEOUT_eps_lb_p_t_indrect_timeout(unsigned int ueps_lb_p_t_indrect_timeout);
int iSetEPS_LB_P_T_INDRECT_DATA_eps_lb_p_t_indrect_data(unsigned int ueps_lb_p_t_indrect_data);
int iSetEPS_P_SOFT_BP_CFG_eps_port_soft_bp_cfg(unsigned int ueps_port_soft_bp_cfg);
int iSetEPS_COS_BP_EN0_eps_cos_bp_en_p0(unsigned int ueps_cos_bp_en_p0);
int iSetEPS_COS_BP_EN0_eps_cos_bp_en_p1(unsigned int ueps_cos_bp_en_p1);
int iSetEPS_COS_BP_EN0_eps_cos_bp_en_p2(unsigned int ueps_cos_bp_en_p2);
int iSetEPS_COS_BP_EN0_eps_cos_bp_en_p3(unsigned int ueps_cos_bp_en_p3);
int iSetEPS_COS_BP_EN1_eps_cos_bp_en_p4(unsigned int ueps_cos_bp_en_p4);
int iSetEPS_COS_BP_EN1_eps_cos_bp_en_p5(unsigned int ueps_cos_bp_en_p5);
int iSetEPS_COS_BP_EN1_eps_cos_bp_en_p6(unsigned int ueps_cos_bp_en_p6);
int iSetEPS_COS_BP_EN1_eps_cos_bp_en_p7(unsigned int ueps_cos_bp_en_p7);
int iSetEPS_BP_MODE_eps_bp_mode(unsigned int ueps_bp_mode);
int iSetEPS_BP_MODE_eps_rw_rsv0(unsigned int ueps_rw_rsv0);
int iSetEPS_ROOT_CIR_CFG_eps_port_grp_cir_cfg(unsigned int ueps_port_grp_cir_cfg);
int iSetEPS_LB_ROOT_CIR_CFG_eps_lb_cir_cfg(unsigned int ueps_lb_cir_cfg);
int iSetEPS_ALL_CIR_CFG_eps_all_cir_cfg(unsigned int ueps_all_cir_cfg);
int iSetEPS_ROOT_CIR_CNT_eps_root_cir_cnt(unsigned int ueps_root_cir_cnt);
int iSetEPS_LB_ROOT_CIR_CNT_eps_lb_root_cir_cnt(unsigned int ueps_lb_root_cir_cnt);
int iSetEPS_ROOT_WGT_CFG_eps_root_wgt_cfg(unsigned int ueps_root_wgt_cfg);
int iSetEPS_NML_ROOT_WGT_CNT_eps_nml_root_wgt_cnt(unsigned int ueps_nml_root_wgt_cnt);
int iSetEPS_LB_ROOT_WGT_CNT_eps_lb_root_wgt_cnt(unsigned int ueps_lb_root_wgt_cnt);
int iSetEPS_ECC_1BIT_ERR_CNT_eps_mem_ecc_err0(unsigned int ueps_mem_ecc_err0);
int iSetEPS_ECC_2BIT_ERR_CNT_eps_mem_ecc_err1(unsigned int ueps_mem_ecc_err1);
int iSetEPS_DQS_CNT_eps_dqs_rec(unsigned int ueps_dqs_rec);
int iSetEPS_EQS_CNT_eps_eqs_rec(unsigned int ueps_eqs_rec);
int iSetEPS_FIFO_CNT_eps_fifo_cnt(unsigned int ueps_fifo_cnt);
int iSetEPS_INNER_ERR_ST_sel_queue_err(unsigned int usel_queue_err);
int iSetEPS_INNER_ERR_ST_dqs_qid_err(unsigned int udqs_qid_err);
int iSetEPS_INNER_ERR_ST_dqs_over_err(unsigned int udqs_over_err);
int iSetEPS_INNER_ERR_ST_dqs_late_err(unsigned int udqs_late_err);

/* Define the union csr_hps_indrect_ctrl_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_indrect_addr : 24; /* [23:0] */
        u32 hps_indrect_tab : 4;   /* [27:24] */
        u32 hps_indrect_stat : 2;  /* [29:28] */
        u32 hps_indrect_mode : 1;  /* [30] */
        u32 hps_indrect_vld : 1;   /* [31] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_hps_indrect_ctrl_u;

/* Define the union csr_hps_indrect_timeout_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_indrect_timeout : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_hps_indrect_timeout_u;

/* Define the union csr_hps_indrect_data_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_indrect_data : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_hps_indrect_data_u;

/* Define the union csr_esch_hps_cppi_shap_type_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hp_shaper_pkt_len : 18;     /* [17:0] */
        u32 rsv_0 : 2;                  /* [19:18] */
        u32 hps_up_shaper_type_cfg : 1; /* [20] */
        u32 rsv_1 : 11;                 /* [31:21] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_cppi_shap_type_cfg_u;

/* Define the union csr_esch_hps_soft_bp_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_port_soft_bp_cfg : 6; /* [5:0] */
        u32 rsv_2 : 26;               /* [31:6] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_soft_bp_cfg_u;

/* Define the union csr_esch_hps_root_shap_type_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hp_root_shaper_pkt_len : 18;  /* [17:0] */
        u32 rsv_3 : 2;                    /* [19:18] */
        u32 hps_root_shaper_type_cfg : 1; /* [20] */
        u32 rsv_4 : 11;                   /* [31:21] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_root_shap_type_cfg_u;

/* Define the union csr_esch_hps_upq_shap_type_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_upq_shaper_type_cfg : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_upq_shap_type_cfg_u;

/* Define the union csr_esch_hps_all_root_wgt_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_root_wgt_cfg : 12; /* [11:0] */
        u32 hps_root_wgt_cfg : 12;    /* [23:12] */
        u32 rsv_5 : 8;                /* [31:24] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_all_root_wgt_cfg_u;

/* Define the union csr_esch_hps_root_cir_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_root_cir_cfg : 25; /* [24:0] */
        u32 rsv_6 : 7;             /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_root_cir_cfg_u;

/* Define the union csr_esch_hps_lb_root_cir_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_root_cir_cfg : 25; /* [24:0] */
        u32 rsv_7 : 7;                /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_root_cir_cfg_u;

/* Define the union csr_esch_hps_lb_p_wgt_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_port_wgt_cfg : 12; /* [11:0] */
        u32 rsv_8 : 20;               /* [31:12] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_p_wgt_cfg_u;

/* Define the union csr_esch_hps_lb_p_cir_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_port_cir_cfg : 25; /* [24:0] */
        u32 rsv_9 : 7;                /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_p_cir_cfg_u;

/* Define the union csr_esch_hps_lb_q_wgt_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_q_wgt_cfg : 12; /* [11:0] */
        u32 rsv_10 : 20;           /* [31:12] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_q_wgt_cfg_u;

/* Define the union csr_esch_hps_lb_q_cir_cfg_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_q_cir_cfg : 25; /* [24:0] */
        u32 rsv_11 : 7;            /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_q_cir_cfg_u;

/* Define the union csr_esch_hps_root_wgt_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_root_wgtcnt : 25; /* [24:0] */
        u32 rsv_12 : 7;           /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_root_wgt_cnt_u;

/* Define the union csr_esch_hps_lb_p_wgt_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_port_wgtcnt : 25; /* [24:0] */
        u32 rsv_13 : 7;              /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_p_wgt_cnt_u;

/* Define the union csr_esch_hps_lb_q_wgt_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_q_wgtcnt : 25; /* [24:0] */
        u32 rsv_14 : 7;           /* [31:25] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_q_wgt_cnt_u;

/* Define the union csr_esch_hps_root_cir_token_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_r_cir_token : 26; /* [25:0] */
        u32 rsv_15 : 6;              /* [31:26] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_root_cir_token_u;

/* Define the union csr_esch_hps_lb_p_cir_token_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_p_cir_token : 26; /* [25:0] */
        u32 rsv_16 : 6;              /* [31:26] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_p_cir_token_u;

/* Define the union csr_esch_hps_lb_q_cir_token_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_lb_q_cir_token : 26; /* [25:0] */
        u32 rsv_17 : 6;              /* [31:26] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_lb_q_cir_token_u;

/* Define the union csr_esch_hps_ecc_1bit_err_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_mem_ecc_err0 : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_ecc_1bit_err_cnt_u;

/* Define the union csr_esch_hps_ecc_2bit_err_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_mem_ecc_err1 : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_ecc_2bit_err_cnt_u;

/* Define the union csr_esch_hps_dqs_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_dqs_rec : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_dqs_cnt_u;

/* Define the union csr_esch_hps_eqs_cnt_u */
typedef union {
    /* Define the struct bits */
    struct {
        u32 hps_eqs_rec : 32; /* [31:0] */
    } bits;

    /* Define an unsigned member */
    u32 value;
} csr_esch_hps_eqs_cnt_u;


// ==============================================================================
/* Define the global struct */
typedef struct {
    volatile csr_hps_indrect_ctrl_u hps_indrect_ctrl;                       /* 0 */
    volatile csr_hps_indrect_timeout_u hps_indrect_timeout;                 /* 4 */
    volatile csr_hps_indrect_data_u hps_indrect_data;                       /* 8 */
    volatile csr_esch_hps_cppi_shap_type_cfg_u esch_hps_cppi_shap_type_cfg; /* 14 */
    volatile csr_esch_hps_soft_bp_cfg_u esch_hps_soft_bp_cfg;               /* 18 */
    volatile csr_esch_hps_root_shap_type_cfg_u esch_hps_root_shap_type_cfg; /* 1C */
    volatile csr_esch_hps_upq_shap_type_cfg_u esch_hps_upq_shap_type_cfg;   /* 60 */
    volatile csr_esch_hps_all_root_wgt_cfg_u esch_hps_all_root_wgt_cfg;     /* 100 */
    volatile csr_esch_hps_root_cir_cfg_u esch_hps_root_cir_cfg;             /* 104 */
    volatile csr_esch_hps_lb_root_cir_cfg_u esch_hps_lb_root_cir_cfg;       /* 108 */
    volatile csr_esch_hps_lb_p_wgt_cfg_u esch_hps_lb_p_wgt_cfg[8];          /* 110 */
    volatile csr_esch_hps_lb_p_cir_cfg_u esch_hps_lb_p_cir_cfg[8];          /* 130 */
    volatile csr_esch_hps_lb_q_wgt_cfg_u esch_hps_lb_q_wgt_cfg[64];         /* 150 */
    volatile csr_esch_hps_lb_q_cir_cfg_u esch_hps_lb_q_cir_cfg[64];         /* 250 */
    volatile csr_esch_hps_root_wgt_cnt_u esch_hps_root_wgt_cnt[2];          /* 400 */
    volatile csr_esch_hps_lb_p_wgt_cnt_u esch_hps_lb_p_wgt_cnt[8];          /* 410 */
    volatile csr_esch_hps_lb_q_wgt_cnt_u esch_hps_lb_q_wgt_cnt[64];         /* 430 */
    volatile csr_esch_hps_root_cir_token_u esch_hps_root_cir_token[2];      /* 530 */
    volatile csr_esch_hps_lb_p_cir_token_u esch_hps_lb_p_cir_token[8];      /* 540 */
    volatile csr_esch_hps_lb_q_cir_token_u esch_hps_lb_q_cir_token[64];     /* 560 */
    volatile csr_esch_hps_ecc_1bit_err_cnt_u esch_hps_ecc_1bit_err_cnt;     /* 660 */
    volatile csr_esch_hps_ecc_2bit_err_cnt_u esch_hps_ecc_2bit_err_cnt;     /* 664 */
    volatile csr_esch_hps_dqs_cnt_u esch_hps_dqs_cnt;                       /* 668 */
    volatile csr_esch_hps_eqs_cnt_u esch_hps_eqs_cnt;                       /* 66C */
} S_esch_hps_csr_REGS_TYPE;

/* Declare the struct pointor of the module esch_hps_csr */
extern volatile S_esch_hps_csr_REGS_TYPE *gopesch_hps_csrAllReg;

/* Declare the functions that set the member value */
int iSetHPS_INDRECT_CTRL_hps_indrect_addr(unsigned int uhps_indrect_addr);
int iSetHPS_INDRECT_CTRL_hps_indrect_tab(unsigned int uhps_indrect_tab);
int iSetHPS_INDRECT_CTRL_hps_indrect_stat(unsigned int uhps_indrect_stat);
int iSetHPS_INDRECT_CTRL_hps_indrect_mode(unsigned int uhps_indrect_mode);
int iSetHPS_INDRECT_CTRL_hps_indrect_vld(unsigned int uhps_indrect_vld);
int iSetHPS_INDRECT_TIMEOUT_hps_indrect_timeout(unsigned int uhps_indrect_timeout);
int iSetHPS_INDRECT_DATA_hps_indrect_data(unsigned int uhps_indrect_data);
int iSetESCH_HPS_CPPI_SHAP_TYPE_CFG_hp_shaper_pkt_len(unsigned int uhp_shaper_pkt_len);
int iSetESCH_HPS_CPPI_SHAP_TYPE_CFG_hps_up_shaper_type_cfg(unsigned int uhps_up_shaper_type_cfg);
int iSetESCH_HPS_SOFT_BP_CFG_hps_port_soft_bp_cfg(unsigned int uhps_port_soft_bp_cfg);
int iSetESCH_HPS_ROOT_SHAP_TYPE_CFG_hp_root_shaper_pkt_len(unsigned int uhp_root_shaper_pkt_len);
int iSetESCH_HPS_ROOT_SHAP_TYPE_CFG_hps_root_shaper_type_cfg(unsigned int uhps_root_shaper_type_cfg);
int iSetESCH_HPS_UPQ_SHAP_TYPE_CFG_hps_upq_shaper_type_cfg(unsigned int uhps_upq_shaper_type_cfg);
int iSetESCH_HPS_ALL_ROOT_WGT_CFG_hps_lb_root_wgt_cfg(unsigned int uhps_lb_root_wgt_cfg);
int iSetESCH_HPS_ALL_ROOT_WGT_CFG_hps_root_wgt_cfg(unsigned int uhps_root_wgt_cfg);
int iSetESCH_HPS_ROOT_CIR_CFG_hps_root_cir_cfg(unsigned int uhps_root_cir_cfg);
int iSetESCH_HPS_LB_ROOT_CIR_CFG_hps_lb_root_cir_cfg(unsigned int uhps_lb_root_cir_cfg);
int iSetESCH_HPS_LB_P_WGT_CFG_hps_lb_port_wgt_cfg(unsigned int uhps_lb_port_wgt_cfg);
int iSetESCH_HPS_LB_P_CIR_CFG_hps_lb_port_cir_cfg(unsigned int uhps_lb_port_cir_cfg);
int iSetESCH_HPS_LB_Q_WGT_CFG_hps_lb_q_wgt_cfg(unsigned int uhps_lb_q_wgt_cfg);
int iSetESCH_HPS_LB_Q_CIR_CFG_hps_lb_q_cir_cfg(unsigned int uhps_lb_q_cir_cfg);
int iSetESCH_HPS_ROOT_WGT_CNT_hps_root_wgtcnt(unsigned int uhps_root_wgtcnt);
int iSetESCH_HPS_LB_P_WGT_CNT_hps_lb_port_wgtcnt(unsigned int uhps_lb_port_wgtcnt);
int iSetESCH_HPS_LB_Q_WGT_CNT_hps_lb_q_wgtcnt(unsigned int uhps_lb_q_wgtcnt);
int iSetESCH_HPS_ROOT_CIR_TOKEN_hps_lb_r_cir_token(unsigned int uhps_lb_r_cir_token);
int iSetESCH_HPS_LB_P_CIR_TOKEN_hps_lb_p_cir_token(unsigned int uhps_lb_p_cir_token);
int iSetESCH_HPS_LB_Q_CIR_TOKEN_hps_lb_q_cir_token(unsigned int uhps_lb_q_cir_token);
int iSetESCH_HPS_ECC_1BIT_ERR_CNT_hps_mem_ecc_err0(unsigned int uhps_mem_ecc_err0);
int iSetESCH_HPS_ECC_2BIT_ERR_CNT_hps_mem_ecc_err1(unsigned int uhps_mem_ecc_err1);
int iSetESCH_HPS_DQS_CNT_hps_dqs_rec(unsigned int uhps_dqs_rec);
int iSetESCH_HPS_EQS_CNT_hps_eqs_rec(unsigned int uhps_eqs_rec);


#endif // ESCH_C_UNION_DEFINE_H
